from functools import partial

RECODE_SIZE = 10

with open('somefile.txt','r',encoding='utf-8') as f:
    recodes = iter(partial(f.read,RECODE_SIZE),r'') # 10 个字符长度
    for r in recodes:
        print(r)